<!DOCTYPE html>
<html lang="en"
      xmlns:th="http://www.thymeleaf.org"
      xmlns:layout="http://www.thymeleaf.org"
      layout:decorator="layout/m_master">

<div layout:fragment="content">
    <style type="text/css">
        .icon_usergroup {
            background-size: contain;
            background-repeat: no-repeat;
            background-position: center;
            width: 1em;
            height: 1em;
            vertical-align: middle;
            margin-top: -.2em;
            display: none;
        }

    </style>
    <div class="page-group">
        <div class="page page_login_public page_register">
            <div th:replace="layout/m_layout::title(${title})"></div>
            <div class="page-content">
                <div class="banner headbox">
                    <img width="100%" style="display: block;" src="/m/img/page_head_bg.png">
                    <div class="text">新用户注册</div>
                </div>
                <div class="loginway" way="mobile">
                    <div class="loginway-navs">
                        <div class="group">
                            <a class="item" way="mobile"
                               onclick="$(&#39;.loginway&#39;).attr(&#39;way&#39;,&#39;mobile&#39;)">手机注册</a>
                            <a class="item" way="email"
                               onclick="$(&#39;.loginway&#39;).attr(&#39;way&#39;,&#39;email&#39;)">邮箱注册</a>
                        </div>
                    </div>
                    <div class="loginway-contet">
                        <div class="loginway-item" way="mobile">
                            <form bottlecms-form-ajax="" id="form_mobile" action="/m/ajax/user/register"
                                  class="registerform" method="post" onsubmit="return checkRegMobile()">
                                <input bottlecms-input="" type="hidden" name="way" value="mobile">
                                <input type="hidden" id="openid" name="openid" th:value="${openid}">
                                <div class="bcui-form" style="padding-top: .5rem;">

                                    <div class="form-item">
                                        <input bottlecms-input="" type="number" name="mobile" id="mobile" value=""
                                               placeholder="手机号">
                                        <i class="ricon icon-bottlecms-45"></i>
                                    </div>
                                    <div class="form-item ub">
                                        <div class="ub ub-f1" style="margin-right: .5rem;">
                                            <input bottlecms-input="" type="number" name="smsyzm" id="smsyzm" value=""
                                                   placeholder="验证码" maxlength="6"
                                                   oninput="if(value.length&gt;6)value=value.slice(0,6)">
                                            <i class="ricon icon-bottlecms-47"></i>
                                        </div>
                                        <div class="ub ub-ac">
                                            <button class="btn btn-warning btn-sm sendSms" type="button">
                                                发送验证码
                                            </button>
                                        </div>
                                    </div>
                                    <div class="form-item">
                                        <input bottlecms-input="" type="password" name="password" id="smsPwd" value=""
                                               placeholder="请输入密码 6-18字符">
                                        <i class="ricon icon-bottlecms-46"></i>
                                    </div>
                                    <div class="form-item" style="font-size: .7rem; padding-left: 10px">
                                        <label>
                                            <input type="checkbox" name="accepted" class="agreement" id="chkSms" value="1">
                                            同意《<a class="_color" style=""
                                                  href="/common/about/agreement"><u>用户许可及服务协议</u></a>》
                                        </label>
                                    </div>
                                    <div class="form-item">
                                        <button class="btn  form-submit" type="submit">
                                            注册
                                        </button>
                                    </div>
                                    <div class="form-item">
                                        <div class="ub-f1" style="text-align: right;">
                                            <a th:href="'/m/login'+${openid==null?'':'?openid='+openid}"
                                                style="color: #999;font-size: .75rem;">已有账号，马上登录&gt;&gt;</a></div>
                                    </div>
                                </div>
                            </form>

                        </div>

                        <div class="loginway-item" way="email">
                                <form bottlecms-form-ajax="" id="form_email" action="/m/ajax/user/register"
                                  class="registerform" method="post" onsubmit="return checkRegEmail()">
                                <input bottlecms-input="" type="hidden" name="way" value="email">
                                <input type="hidden" id="openid" name="openid" th:value="${openid}">
                                    <div class="bcui-form" style="padding-top: .5rem;">

                                    <div class="form-item">
                                        <input bottlecms-input="" type="text" name="email" value="" id="email" placeholder="邮箱">
                                        <i class="ricon icon-bottlecms-78"></i>
                                    </div>
                                    <div class="form-item ub">
                                        <div class="ub ub-f1" style="margin-right: .5rem;">
                                            <input bottlecms-input="" type="number" name="emailyzm" id="emailyzm" value=""
                                                   placeholder="验证码" maxlength="6"
                                                   oninput="if(value.length&gt;6)value=value.slice(0,6)">
                                            <i class="ricon icon-bottlecms-47"></i>
                                        </div>
                                        <div class="ub ub-ac">
                                            <button class="btn btn-warning btn-sm sendEmail" type="button">
                                                发送验证码
                                            </button>
                                        </div>
                                    </div>

                                    <div class="form-item">
                                        <input bottlecms-input="" type="password" maxlength="18" name="password" id="emailPwd" value=""
                                               placeholder="请输入密码 6-18字符">
                                        <i class="ricon icon-bottlecms-46"></i>
                                    </div>
                                    <div class="form-item" style="font-size: .7rem; padding-left: 10px">
                                        <label>
                                            <input type="checkbox" name="accepted" class="agreement" id="chkEmail" value="1">
                                            同意《<a class="_color" style=""
                                                  href="/common/about/agreement"><u>用户许可及服务协议</u></a>》
                                        </label>
                                    </div>
                                    <div class="form-item">
                                        <button class="btn  form-submit" type="submit">
                                            注册
                                        </button>
                                    </div>
                                    <div class="form-item">
                                        <div class="ub-f1" style="text-align: right;"><a href="/m/login"
                                                style="color: #999;font-size: .75rem;">已有账号，马上登录&gt;&gt;</a></div>
                                    </div>
                                </div>
                            </form>

                        </div>
                    </div>
                </div>
                <div style="height: 60px;"></div>

            </div>
        </div>
    </div>
    <div th:replace="layout/m_layout::systemJs"></div>
    <script id="javascript-bottlecms-page" src="/m/js/user/register.js" type="text/javascript"></script>

</div>
</html>
